home *** CD-ROM | disk | FTP | other *** search
- Path: sunrise.gv.ssi1.com!news
- From: Mike Palmer <Mike.Palmer@tus.ssi1.com>
- Newsgroups: comp.lang.c++
- Subject: Re: Hungarian notation
- Date: Sat, 06 Jan 1996 15:23:02 -0800
- Organization: Silicon Systems, Inc.
- Message-ID: <30EF0456.60A2@tus.ssi1.com>
- References: <30C40F77.53B5@swsbbs.com> <4behis$3cl@dux.dundee.ac.uk>
- <RIGOTTI.95Dec29100514@roach.dra.hmg.gb>
- <4cd8fc$oud@news.manawatu.gen.nz> <HtlknJAZAQ7wEwjl@wndrwrks.demon.co.uk> <60KgWmb-3RB@herold.franken.de>
- NNTP-Posting-Host: tu155.tus.ssi1.com
- Mime-Version: 1.0
- Content-Type: text/plain; charset=us-ascii
- Content-Transfer-Encoding: 7bit
- X-Mailer: Mozilla 2.0b2 (X11; I; HP-UX A.09.05 9000/715)
-
- Joachim Durchholz wrote:
- >
- > > Consider also that variable names may be misleading anyway. In that
- > > sense there's no great difference between
- > >
- > > someProc(MyString)
- > >
- > > and
- > >
- > > someProc(pszMyString)
- > >
- > > either could quite happily refer to any other data type.
- > >
- >
- > This example does not occur in real life. Or rather, it better should not!
- > Anybody using meaningless names like "MyString" should be thrown out of
- > the programming business. Depending on the actual semantics of "someProc",
- > the parameter should be called "Message" or "Options" or "ParserInput" or
- > whatever.
- >
- > -Joachim
-
- One hopes you just missed the point here. Hungarian notation does not attempt
- to help you keep track of _what_ your variable is, it gives you a framework
- to keep track of what _kind_ of variable it is. One would also note that
- someProc is not a very descriptive name, but so what? In the first example, I
- have _no_ clue what type of variable MyString is, although I could probably
- deduce that it is a string. In the second example, the prefix tells me that
- it is a Pointer to a Zero terminated String.
-
- -- Mike --
-
- ---- Mike Palmer --------------- Mike.Palmer@tus.ssi1.com ----
- ---- The opinions expressed here are mine, and ----
- ---- not those of my employer or of TDK. ----
-